<?php

namespace Admin\Controller;
use Think\Controller;
class RoleController extends Controller{
    public function show(){
        $role=D('role');
        $info=$role->select();
        $this->assign('info',$info);
        $this->display();
    }

    public function distribute($id){
        if(!empty($_POST)){
             dump($_POST);
        }
        $role=D('role');
        $info=$role->find($id);

        $this->assign('info',$info);

            $listA=D('Auth')->where("a_level=0")->select();
            $listB=D('Auth')->where("a_level=1")->select();

        $this->assign('listA',$listA);
        $this->assign('listB',$listB);


        $this->display();
    }


}